home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 1 / Amiga Tools.iso / egs-tools / egs_demo-version / egs_devels / doc / gbscrollbox.doc < prev    next >
Text File  |  1994-06-06  |  7KB  |  332 lines

  1. /*
  2. *  $
  3. *  $ FILE     : gbscrollbox.doc
  4. *  $ VERSION  : 1
  5. *  $ REVISION : 1
  6. *  $ DATE     : 08-Feb-93 10:01
  7. *  $
  8. *  $ Author   : mvk
  9. *  $
  10. *
  11. *
  12. * (c) Copyright 1990/93 VIONA Development
  13. *     All Rights Reserved
  14. *
  15. */
  16.  
  17. gbscrollbox.library/EGB_ActivateElem
  18. gbscrollbox.library/EGB_AddItemToScrollBox
  19. gbscrollbox.library/EGB_AddListToScrollBox
  20. gbscrollbox.library/EGB_CreateLateScrollBox
  21. gbscrollbox.library/EGB_LinkStringToScroll
  22. gbscrollbox.library/EGB_NextElem
  23. gbscrollbox.library/EGB_PrevElem
  24. gbscrollbox.library/EGB_RemItemFromScrollBox
  25. gbscrollbox.library/EGB_RemListFromScrollBox
  26. gbscrollbox.library/EGB_SetTopElem
  27. gbscrollbox.library/EGB_UpdateScrollBox
  28.  
  29.  
  30. gbscrollbox.library/EGB_ActivateElem
  31. NAME
  32.   EGB_ActivateElem
  33.  
  34. SYNOPSIS
  35.   EGB_ActivateElem(win, gad, item);
  36.            A0   A1   A2
  37.  
  38.   EI_WindowPtr    win;
  39.   EI_GadgetPtr    gad;
  40.   struct Node     *item;
  41.  
  42. FUNCTION
  43.   Activates an item from a gadbox scrollbox gadget. Moves the scrollbox view
  44.   if necessary.
  45.  
  46. INPUTS
  47.   win    : The window that contains the gadget; if NULL, no refresh is done
  48.   gad    : the scrollbox gadget
  49.   item   : Pointer to the item (node) to be activated
  50.  
  51. RETURNS
  52.  
  53.  
  54.  
  55.  
  56. gbscrollbox.library/EGB_AddItemToScrollBox
  57. NAME
  58.   EGB_AddItemToScrollBox
  59.  
  60. SYNOPSIS
  61.   EGB_AddItemToScrollBox(win, gad, item);
  62.              A0   A1   A2
  63.  
  64.   EI_WindowPtr     win;
  65.   EI_GadgetPtr     gad;
  66.   struct Node      *item;
  67.  
  68. FUNCTION
  69.   Adds an item to a scroll box. Make sure that this item is not an element of
  70.   a second list, as it is inserted into the scrollbox's list. If the sort flag
  71.   is set, the item will be inserted in alphabetical order.
  72.  
  73. INPUTS
  74.   win    : The window, that contains the gadget; if NULL, no refresh is done
  75.   gad    : The scrollbox gadget
  76.   item   : The item to be inserted in to the scrollbox
  77.  
  78. RETURNS
  79.  
  80.  
  81.  
  82.  
  83. gbscrollbox.library/EGB_AddListToScrollBox
  84. NAME
  85.   EGB_AddListToScrollBox
  86.  
  87. SYNOPSIS
  88.   EGB_AddListToScrollBox(win, gad, list);
  89.              A0   A1   A2
  90.  
  91.   EI_WindowPtr    win;
  92.   EI_GadgetPtr    gad;
  93.   struct List     *list;
  94.  
  95. FUNCTION
  96.   Adds the elements of the list to the scrollbox. The original list is
  97.   destroyed, as the elements are not cloned, but used as they are.
  98.  
  99. INPUTS
  100.   win      : Window that contains the gadget; if NULL, no refresh is done
  101.   gad      : the scrollbox gadget
  102.   list     : The list containing the elements to be inserted into the
  103.          scrollbox.
  104.  
  105. RETURNS
  106.  
  107.  
  108.  
  109.  
  110. gbscrollbox.library/EGB_CreateLateScrollBox
  111. NAME
  112.   EGB_CreateLateScrollBox
  113.  
  114. SYNOPSIS
  115.   box = EGB_CreateLateScrollBox(con, minWidth, maxWidth, minHeight, maxHeight,
  116.   D0                            A0   D0        D1        D2         D3
  117.                 sort, id);
  118.                 D4    D5
  119.  
  120.   EB_GadBoxPtr     box;
  121.   EB_GadContext    con;
  122.   WORD             minWidth, maxWidth, minHeight, maxHeight;
  123.   ULONG            sort;
  124.   LONG             id;
  125.  
  126. FUNCTION
  127.   Creates a gadbox scrollbox gadget. These gadgets offer a list of Textlines,
  128.   in which the user can scroll using a propgadget. One item can be selected
  129.   at any time. This item is highlighted. The size information gives only
  130.   minimum and maximum values in characters and lines. The number of displayed
  131.   lines and collumns in the gadget depents on the surrounding gadboxes.
  132.  
  133. INPUTS
  134.   con       : The associated gadget context
  135.   minWidth  : the minimal requiered number of collumns
  136.   maxWidth  : the maximal allowed number of collumns
  137.   minHeight : the minimal requiered number of lines
  138.   maxHeight : the maximal allowed number of lines
  139.   sort      : boolean value, if true, the scrollbox elements are sorted
  140.           by their priority and string.
  141.  
  142. RETURNS
  143.  
  144.  
  145.  
  146.  
  147. gbscrollbox.library/EGB_LinkStringToScroll
  148. NAME
  149.   EGB_LinkStringToScroll
  150.  
  151. SYNOPSIS
  152.   EGB_LinkStringToScroll(scroll, string);
  153.              A0      A1
  154.  
  155.   EI_GadgetPtr      scroll;
  156.   EI_GadgetPtr      string;
  157.  
  158. FUNCTION
  159.   Links a string gadget to a scroll box. If an item from the scrollbox is
  160.   activated, the associated string will be copied to the string gadget.
  161.   The area of the scroll gadget will follow the value in the string gadget,
  162.   when ever that is modified
  163.  
  164. INPUTS
  165.   scroll      : a scrollbox gadget
  166.   string      : a string gadget
  167.  
  168. RETURNS
  169.  
  170.  
  171.  
  172.  
  173. gbscrollbox.library/EGB_NextElem
  174. NAME
  175.   EGB_NextElem
  176.  
  177. SYNOPSIS
  178.   EGB_NextElem(win, gad);
  179.            A0   A1
  180.  
  181.   EI_WindowPtr  win;
  182.   EI_GadgetPtr  gad;
  183.  
  184. FUNCTION
  185.   Activates the next element of a scrollbox gadget. If none is selected
  186.   the first entry will become the selected one.
  187.  
  188. INPUTS
  189.   win    : The window that contains the gadget, if NULL, no refresh is done
  190.   gad    : The scrollbox gadget
  191.  
  192. RETURNS
  193.  
  194.  
  195.  
  196.  
  197. gbscrollbox.library/EGB_PrevElem
  198. NAME
  199.   EGB_PrevElem
  200.  
  201. SYNOPSIS
  202.   EGB_PrevElem(win, gad);
  203.            A0   A1
  204.  
  205.   EI_WindowPtr   win;
  206.   EI_GadgetPtr   gad;
  207.  
  208. FUNCTION
  209.   Activates the previous element in a scrollbox gadget. If none is selected,
  210.   the last one will become the selected one.
  211.  
  212. INPUTS
  213.   win    : The window that contains the gadget; if NULL, no refresh is done
  214.   gad    : The scrollbox gadget
  215.  
  216. RETURNS
  217.  
  218.  
  219.  
  220.  
  221. gbscrollbox.library/EGB_RemItemFromScrollBox
  222. NAME
  223.   EGB_RemItemFromScrollBox
  224.  
  225. SYNOPSIS
  226.   EGB_RemItemFromScrollBox(win, gad, item);
  227.                A0   A1   A2
  228.  
  229.   EI_WindowPtr    win;
  230.   EI_GadgetPtr    gad;
  231.   struct Node     *item;
  232.  
  233. FUNCTION
  234.   Removes an item from a scrollbox.
  235.  
  236. INPUTS
  237.   win    : The window, that contains the gadget; if NULL, no refresh is done
  238.   gad    : The scrollbox gadget
  239.   item   : The element to remove, must be in the scrollbox
  240.  
  241. RETURNS
  242.  
  243.  
  244.  
  245.  
  246. gbscrollbox.library/EGB_RemListFromScrollBox
  247. NAME
  248.   EGB_RemListFromScrollBox
  249.  
  250. SYNOPSIS
  251.   EGB_RemListFromScrollBox(win, gad, list);
  252.                A0   A1   A2
  253.  
  254.   EI_WindowPtr    win;
  255.   EI_GadgetPtr    gad;
  256.   struct List     *list;
  257.  
  258. FUNCTION
  259.   Removes all items from a scrollbox and puts them into the list. This list
  260.   may later be added to the scrollbox again.
  261.  
  262. INPUTS
  263.   win     : The window that contains the gadget; if NULL, no refresh is done
  264.   gad     : The scrollbox gadget
  265.   list    : an empty list
  266.  
  267. RETURNS
  268.   list    : A list, that contains all items that were in the scrollbox before.
  269.  
  270.  
  271.  
  272.  
  273.  
  274. gbscrollbox.library/EGB_SetTopElem
  275. NAME
  276.   EGB_SetTopElem
  277.  
  278. SYNOPSIS
  279.   EGB_SetTopElem(win, gad, item);
  280.          A0   A1   A2
  281.  
  282.   EI_WindowPtr   win;
  283.   EI_GadgetPtr   gad;
  284.   struct Node    *item;
  285.  
  286. FUNCTION
  287.   Changes the visible area of a scrollbox gadget.
  288.  
  289. INPUTS
  290.   win     : The window that contains the gadget; if NULL, no refresh is done
  291.   gad     : The scrollbox gadget
  292.   item    : This item will become the topmost one in the visible area of the
  293.         scrollgadget
  294.  
  295. RETURNS
  296.  
  297.  
  298.  
  299.  
  300. gbscrollbox.library/EGB_UpdateScrollBox
  301. NAME
  302.   EGB_UpdateScrollBox
  303.  
  304. SYNOPSIS
  305.   EGB_UpdateScrollBox(win, gad);
  306.               A0   A1
  307.  
  308.   EI_WindowPtr    win;
  309.   EI_GadgetPtr    gad;
  310.  
  311. FUNCTION
  312.   Updates a scrollbox, after its item list has be changed manually. You must
  313.   call this function every time you have changed the item list. But don't
  314.   forget to lock egsintui (EI_LockIntution) while you work in the gadgets
  315.   private data structure. In general it is better to remove the list from
  316.   the scrollbox, work outside and add it again afterwards.
  317.   If you want to avoid that the empty gadget is drawn after you removed
  318.   the items, call EGB_RemListFromScrollBox with win=NULL. But make sure
  319.   that you add the items again after the operation.
  320.  
  321. INPUTS
  322.   win     : The window that contains the gadget; if NULL, no refresh is done
  323.   gad     : The scrollbox gadget
  324.  
  325. RETURNS
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.